package com.ruoyi.biz.letter.domain;

import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.biz.attchment.domain.BizAttachment;
import com.ruoyi.biz.letter.read.HandleMethodConverter;
import com.ruoyi.biz.letter.read.YesOrNoConverter;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ruoyi.common.core.domain.BaseEntity;

import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

/**
 * 督办事项登记对象 biz_record_letter
 *
 * @author Fei.Cong
 * @date 2024-07-11
 */
@TableName(value = "biz_record_letter")
public class BizRecordLetter extends CategoryBase {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    private Long id;

    /**
     * 来件单位
     */
    @ExcelProperty("来件单位")
    private String letterCorp;

    /**
     * 属地
     */
    @ExcelProperty("地市")
    private String ownerArea;

    /**
     * 信访人姓名
     */
    @ExcelProperty("姓名")
    private String letterUsername;

    /**
     * 信访人身份证号
     */
    @ExcelProperty("身份证号")
    private String letterCardno;

    /**
     * 信访人身份证号
     */
    @ExcelProperty("联系方式")
    private String letterTel;

    /**
     * 具体事项
     */
    @ExcelProperty("信访情况")
    private String letterContent;

    /**
     * 办理要求
     */
    @ExcelProperty("办理要求")
    private String handleContent;

    /**
     * 来件时间
     */
    @ExcelProperty("来件时间")
    private Date letterTime;

    /**
     * 经办人
     */
    @ExcelProperty("经办人")
    private String handleBy;

    /**
     * 处理方式，1-交办，2-转送，3-自办
     */
    @ExcelProperty(value = "处理方式", converter = HandleMethodConverter.class)
    private String handleMethod;

    /**
     * 办理情况
     */
    @ExcelProperty("办理情况")
    private String handleResult;

    /**
     * 数据来源，1-来信，2-来电，3-来访
     */
    @ExcelProperty("数据来源")
    private String source;

    /**
     * 案件类型
     */
    @ExcelProperty("案件类型")
    private String caseType;

    /**
     * 流水号
     */
    private String serialNumber;

    /**
     * 责任处室
     */
    @TableField(exist = false)
    @ExcelProperty("责任处室")
    private String dutyDept;

    /**
     * 登记备注
     */
    private String signRemark;

    /**
     * 部门id
     */
    private Long deptId;

    /**
     * 删除标志（0代表存在 2代表删除）
     */
    private String delFlag;

    @ExcelProperty(value = "是否办结", converter = YesOrNoConverter.class)
    private String isFinish;

    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date finishTime;

    @TableField(exist = false)
    private String attachments;

    @TableField(exist = false)
    private String attachments1;

    /**
     * 上方人数
     */
    @ExcelProperty("上访人数")
    private Integer num;

    /**
     * 是否群访
     */
    private String isGroup;

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public void setLetterCorp(String letterCorp) {
        this.letterCorp = letterCorp;
    }

    public String getLetterCorp() {
        return letterCorp;
    }

    public void setDeptId(Long deptId) {
        this.deptId = deptId;
    }

    public Long getDeptId() {
        return deptId;
    }

    public void setLetterUsername(String letterUsername) {
        this.letterUsername = letterUsername;
    }

    public String getLetterUsername() {
        return letterUsername;
    }

    public void setLetterContent(String letterContent) {
        this.letterContent = letterContent;
    }

    public String getLetterContent() {
        return letterContent;
    }

    public void setHandleContent(String handleContent) {
        this.handleContent = handleContent;
    }

    public String getHandleContent() {
        return handleContent;
    }

    public Date getLetterTime() {
        return letterTime;
    }

    public void setLetterTime(Date letterTime) {
        this.letterTime = letterTime;
    }

    public void setHandleBy(String handleBy) {
        this.handleBy = handleBy;
    }

    public String getHandleBy() {
        return handleBy;
    }

    public void setHandleResult(String handleResult) {
        this.handleResult = handleResult;
    }

    public String getHandleResult() {
        return handleResult;
    }

    public void setCaseType(String caseType) {
        this.caseType = caseType;
    }

    public String getCaseType() {
        return caseType;
    }

    public void setSerialNumber(String serialNumber) {
        this.serialNumber = serialNumber;
    }

    public String getSerialNumber() {
        return serialNumber;
    }

    public void setSignRemark(String signRemark) {
        this.signRemark = signRemark;
    }

    public String getSignRemark() {
        return signRemark;
    }

    public String getOwnerArea() {
        return ownerArea;
    }

    public void setOwnerArea(String ownerArea) {
        this.ownerArea = ownerArea;
    }

    public String getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(String delFlag) {
        this.delFlag = delFlag;
    }

    public String getLetterCardno() {
        return letterCardno;
    }

    public void setLetterCardno(String letterCardno) {
        this.letterCardno = letterCardno;
    }

    public String getHandleMethod() {
        return handleMethod;
    }

    public void setHandleMethod(String handleMethod) {
        this.handleMethod = handleMethod;
    }

    public String getSource() {
        return source;
    }

    public void setSource(String source) {
        this.source = source;
    }

    public String getLetterTel() {
        return letterTel;
    }

    public void setLetterTel(String letterTel) {
        this.letterTel = letterTel;
    }

    public String getAttachments() {
        return attachments;
    }

    public void setAttachments(String attachments) {
        this.attachments = attachments;
    }

    public String getIsFinish() {
        return isFinish;
    }

    public void setIsFinish(String isFinish) {
        this.isFinish = isFinish;
    }

    public Date getFinishTime() {
        return finishTime;
    }

    public void setFinishTime(Date finishTime) {
        this.finishTime = finishTime;
    }

    public String getAttachments1() {
        return attachments1;
    }

    public void setAttachments1(String attachments1) {
        this.attachments1 = attachments1;
    }

    public String getDutyDept() {
        return dutyDept;
    }

    public void setDutyDept(String dutyDept) {
        this.dutyDept = dutyDept;
    }

    public Integer getNum() {
        return num;
    }

    public void setNum(Integer num) {
        this.num = num;
    }

    public String getIsGroup() {
        return isGroup;
    }

    public void setIsGroup(String isGroup) {
        this.isGroup = isGroup;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("letterCorp", getLetterCorp())
                .append("ownerArea", getOwnerArea())
                .append("letterUsername", getLetterUsername())
                .append("letterContent", getLetterContent())
                .append("handleContent", getHandleContent())
                .append("letterTime", getLetterTime())
                .append("handleBy", getHandleBy())
                .append("handleResult", getHandleResult())
                .append("caseType", getCaseType())
                .append("serialNumber", getSerialNumber())
                .append("signRemark", getSignRemark())
                .append("deptId", getDeptId())
                .append("delFlag", getDelFlag())
                .append("createBy", getCreateBy())
                .append("createTime", getCreateTime())
                .append("updateBy", getUpdateBy())
                .append("updateTime", getUpdateTime())
                .append("remark", getRemark())
                .toString();
    }
}
